import React from "react";
import {SearchBar} from "antd-mobile";
import style from './index.module.css'
const {search} = style

export default function Search(){
    function handlerFocus(){
        console.log('Focus')
    }

    function handlerChange(value:string){
        console.log(value)
    }

    return (

            <SearchBar
                className={search}
                placeholder='请输入内容'
                clearable
                showCancelButton
                onFocus={handlerFocus}
                //使取消按钮常驻
                // showCancelButton={() => true}
                onChange={handlerChange}
                style={{
                    '--border-radius':'0',
                }}
            />
    )
}